I./Related INTRODUCTION
1/rsync
Rsync,remotesynchronize as implies know it is a remote synchronization of the software, it synchronizes files at the same time, you can keep the original file permissions, time, soft and hard links and other additional information. Rsync uses the rsync algorithm to provide a quick wa
Powerful rsync website automatic backup tool
Rsync is a data image backup tool in unix-like systems-remote sync. A Fast Incremental Backup Tool, Remote Sync, supports local replication or synchronization with other SSH and rsync hosts. Compared with traditional cp, scp, and tar backup methods,
Rsync is a fast incremental file transfer tool. It can be used for internal backup of the same host. We can also use it as a network backup tool for different hosts. This article mainly describes how to use an rsync server to implement file transmission, backup, and mirroring. Compared with tar and wget, rsync also has its own advantages, such as fast, secure, an
-tools on the master server
Tar-zxvf inotify-tools-3.14.tar.gzCd inotify-tools-3.14./Configure-prefix =/usr/local/inotifyMake make install
Configure the rsync password file on the master server to synchronize data to the slave server.Vim/etc/rsync. passwd# PasswordRsync
Create scriptVim inotifyrsync. sh
#! /Bin/bashHost = 192.168.6.36Src =/usr/local/nginx/html/wordpress/Dst = wordpressUser = rsyncInotifywa
Rsync+inotify configuration of automatic backup server1 Backing up the server ip:192.168.1.106Client ip:192.168.1.1072.#yum-y install rsync xinetd gcc gcc-c++Install both of these services, as well as the C + + compiler (if not in advance, to avoid the compiler when compiling binary files)3. Create a rsyncd.conf on the server side (192.168.1.106)/etc#service ipta
Recently need to write a script to backup each server on the program to a designated server, originally thought to check the use of the rsync command 321 can be done, the results of the rsync command to support automatic login or to configure the service and parameters, and not sure the network said the configuration of the line, because all is a kind, However, t
First, rsync is a Unix-like system of data mirroring backup tools, from the name of the software can be seen-remote sync
Features are as follows:
1, can be mirrored to save the entire directory tree and file system.
2, it is easy to maintain the original file permissions, time, soft and hard links and so on.
3, no special permission can be installed.
4, the optimized process, the file transmission efficiency is high.
5, can use RCP, ssh and othe
Linux (Debian and Fedora) using rsync synchronization tool to automatically synchronize Remote Server File installation and configuration steps: # cdrsync-3.0.5 #. config
Linux (Debian and FEdUsing rsyNcThe synchronization tool automatically synchronizes the installation and configuration steps of remote server files:
I. Installation1. Debian/Ubuntu# Apt-get install rSync(Directly use the built-in download
Remote Automatic Backup rsync + ssh + sshpass: the advantages of mutual automatic backup between remote servers (www.2cto.com rsync) The vast majority of O M personnel know that, simply put, only the files that have been modified are backed up, reduce data transmission volume. At the same time, it can transmit data th
First, rsync is a Unix-like system of data mirroring backup tools, from the name of the software can be seen-remote syncFeatures are as follows:1, can be mirrored to save the entire directory tree and file system.2, it is easy to maintain the original file permissions, time, soft and hard links and so on.3, no special permission can be installed.4, the optimized process, the file transmission efficiency is high.5, can use RCP, ssh and other means to t
-side IP
#第二个zrblog为服务器端设定的自定义命名
#最后的/home/wwwroot is a synchronized Web site Directory
Then, set the permissions
The code is as follows
Copy Code
chmod +x/root/rs.sh
When you have completed the above settings, please run/root/rs.sh on the client manually to detect the success of the normal sync.
Add that if you use the Iptalbes, please note that rsync requires open port 873, otherwise it is not sy
Rsync is a data image backup tool in unix-like systems. It can be used not only in linux systems, but also in windows systems and cross-platform data backup. Now many webmasters use it.
Requirement: content on a server is backed up to a remote disaster recovery server on a regular basis every day. To save space and improve transmission efficiency, Incremental backup is used.Expansion requirement: the two servers synchronize all data in a directory in
You can use the xinetd service to manage rsync for automatic start and xinetdrsync.1.1 xinetd service configuration 1.1.1 check whether the xinetd service is installed
[Root @ backup ~] # Rpm-qa xinetd
[Root @ backup ~] # Rpm-ql xinetd
Package xinetd is not installed1.1.2 install the xinetd service
[Root @ backup ~] # Yum install xinetd-y
[Root @ backup ~] # Rpm-qa xinetd
Xinetd-2.3.14-40.el6.x86_641.2
If the server disables password logon, you must use KEY,RSYNC-E "Ssh-i key" to resolve it, but the password requires non-interactive input (manual input), and scheduled task execution cannot be manually guarded.Combining expect can realize automatic input password
Instance Code
The code is as follows
Copy Code
#!/usr/bin/expectSet Timeout 30Spawn
There are many servers and databases in our production system, and daily backup is especially important. However, it is often the easiest way to ignore a disaster-free backup. However, when a disaster occurs, backup is the most direct and useful solution, although some data losses are inevitable.Rsync is a secure backup software with simple configuration and comprehensive functions. For more information, see the manual. Here we will share with you the deployment of
Now there is a need, a server under a path to the file, want to back up to the B server below. Suppose a IP is 192.168.1.75,b IP is 192.168.1.85. Under Ubuntu you can use the Rsync software to work with the INotify tool to implement this feature.
1 rsync host-side configuration
The ubuntu16.03 system already has the Rsync software installed by default. You need t
A description of the application scenarioThere are several game suits running PHP code on the back end of LB, the same as PHP code for each server's environment deployment. It is now sometimes necessary to change the game profile, such as changing the service state of each area. Logging on to each server to change the corresponding files is cumbersome and requires the configuration files on the other server to change automatically when the configuration file on the first server is changed. So co
INOTIFY+RSYNC+MUTT+MSMTP implement Linux file or directory Automatic Update and implement email to admin
Implement real-time synchronization of files and monitor directory to send mail to admin
requirements, need to update multiple servers, manual, long time.
and real-time monitoring to send mail to the administrator's mailbox.
Server architecture Diagram
Update Source ip:192.168.0.110
Server ip:192
First, server-side configuration:
Install Rsync
#系统一般是默认安装的
If it is not installed you can go to the installation CD (my system is CentOS4.6 so it is in the \centos\rpms\ directory of the first CD)
#配置/etc/rsyncd.conf
#系统上rsync安装后, did not create the rsyncd.conf document, the author is the rsyncd.conf document created by myself
[Root@rsync ~]#
Uid=nobody # This
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.